const { injectBabelPlugin } = require('react-app-rewired');
const rewireLess = require('react-app-rewire-less');

module.exports = function override(config, env) {
    // config = injectBabelPlugin(['import', { libraryName: 'antd', libraryDirectory: 'es', style: 'css' }], config);
    config = injectBabelPlugin(['import', { libraryName: 'antd', style: true }], config);
    config = rewireLess.withLoaderOptions({
        modifyVars: { 
            // "@primary-color": "#487298", 
            // "@layout-header-background": "#1a1f0f",
            // "@menu-dark-submenu-bg": "#333744",
            // "@layout-trigger-background": "#91ce0d",
            "@font-size-base": "13px"
        },
        
    })(config, env);
    return config;
};